package com.note.service.impl;

import com.note.domain.SftpContext;
import com.note.service.FilePathProductServiceI;
import com.note.common.utils.uuid.IdUtils;
import org.springframework.stereotype.Service;


/**
 * 文件服务名服务
 */
@Service
public class FilePathProductServiceImpl implements FilePathProductServiceI {


    @Override
    public String productSftpPath(SftpContext sftpContext) {
        StringBuilder stringBuilder = new StringBuilder();
        stringBuilder.append(sftpContext.getUserName()+"/"+ IdUtils.randomUUID()+"."+sftpContext.getSubbfix());
        return stringBuilder.toString();
    }
}
